home *** CD-ROM | disk | FTP | other *** search
/ Shareware Grab Bag / Shareware Grab Bag.iso / 015 / prt.arc / PRT.DOC < prev   
Encoding:
Text File  |  1986-11-24  |  10.3 KB  |  181 lines

  1.  
  2. The IBM Personal Computer file print command, PRT, is used to print a PC-DOS
  3. file on a device attached to the serial port.  It is most useful for printing
  4. a file when other than a straight line-by-line listing, such as that obtained
  5. by using ctl-PrtSc in conjunction with the TYPE command, is desired or when
  6. special printer features are to be used.
  7.  
  8. The format of the PRT command is:
  9.  
  10. +-------+---------------------------------------------------------------------+
  11. |       |                                                                     |
  12. |  PRT  |  [filespec [/][option] [/][...][;]                                  |
  13. |       |                                                                     |
  14. |       |  options:                                                           |
  15. |       |  INIT    RESET    ENLarged    CONDensed    ENHanced    EMPHasized   |
  16. |       |  NOINIT  NORESET  NOENLarged  NOCONDensed  NOENHanced  NOEMPHasized |
  17. |       |                                                                     |
  18. |       |  HEX    Header    CC    LPI 6  PAGESIze n  FROM n  FOR n            |
  19. |       |  NOHEX  UHeader   NOCC      8                                       |
  20. |       |         NOHeader                                                    |
  21. |       |                                                                     |
  22. +-------+---------------------------------------------------------------------+
  23.  
  24. where:
  25.  
  26. filespec     specifies the PC-DOS file name and file extension ("filetype") of
  27.              the disk file to be printed.  "filespec" may optionally be pre-
  28.              fixed with a drive specification (e.g., "B:") to override the
  29.              current default drive.  If "filespec" is specified as "?", a
  30.              brief summary of the PRT command options are displayed on the
  31.              monitor.
  32.  
  33.              If "filespec" is omitted, you will be prompted ("IN_FILE: ") to
  34.              enter it from the terminal.
  35.  
  36.              If no options are specified following "filespec", you will be
  37.              prompted ("OPTIONS: ") to enter them from the terminal.  If you
  38.              are satisfied with the default values for all the options, and
  39.              don't want to enter a null line in response to the "OPTIONS: "
  40.              prompt, you can specify the character ";" following "filespec"
  41.              to suppress the prompt and cause the defaults to be used.
  42.  
  43. options:
  44.  
  45. INIT         specifies that various codes, as specified by the [NO]ENLARGED,
  46.              [NO]CONDENSED, [NO]ENHANCED, [NO]EMPHASIZED, and LPI n options
  47.              (or their associated defaults), are to be sent to the printer
  48.              prior to printing the file.  This is the default.
  49.  
  50. NOINIT       specifies that NO printer codes are to be sent prior to printing
  51.              the file--in other words, the printer attributes in effect prior
  52.              to issuing the PRT command are used for printing the file.  Spec-
  53.              ifying the NOINIT option causes the specification of any of the
  54.              following options (or their negations) to be ignored:  ENLARGED,
  55.              CONDENSED, ENHANCED, EMPHASIZED, and LPI.
  56.  
  57. RESET        specify whether (RESET) or not (NORESET) the default printer
  58. NORESET      attributes are to be restored after the file has been printed.
  59.              RESET is the default.  If RESET is specified or allowed to
  60.              default, the printer attributes are reset to: NOENLARGED,
  61.              NOCONDENSED, NOEMPHASIZED, NOENHANCED, LPI 8, and no "skip over
  62.              perferations".
  63.  
  64. ENLARGED     specify whether (ENLARGED) or not (NOENLARGED) the file is to be
  65. NOENLARGED   printed using the "enlarged" character set generated by the
  66.              printer.  NOENLARGED is the default.  Note that ENLARGED can be
  67.              combined with CONDENSED to produce "enlarged condensed"
  68.              characters which are different in size from normal, enlarged,
  69.              and condensed characters.
  70.  
  71. CONDENSED    specify whether (CONDENSED) or not (NOCONDENSED) the file is to
  72. NOCONDENSED  be printed using the "condensed" character set generated by the
  73.              printer.  NOCONDENSED is the default.  Note that CONDENSED can
  74.              be combined with ENLARGED to produce "enlarged condensed"
  75.              characters which are different in size from normal, enlarged,
  76.              and condensed characters.
  77.  
  78. ENHANCED     specify whether (ENHANCED) or not (NOENHANCED) the characters
  79. NOENHANCED   are to be double printed (by printing the character, advancing
  80.              the paper by 1/216 inch, and then printing the same character
  81.              again).  NOENHANCED is the default.
  82.  
  83. EMPHASIZED   specify whether (EMPHASIZED) or not (NOEMPHASIZED) the characters
  84. NOEMPHASIZED are to be given a strong impression on the printer.  NOEMPHASIZED
  85.              is the default.
  86.  
  87. HEX          specify whether (HEX) or not (NOHEX) lines are to be printed
  88. NOHEX        along with the hexadecimal representation of each byte.  If HEX
  89.              is specified, each line from the input file is preceded by a
  90.              line on the printer containing the input file line number and
  91.              length.  The the line itself is printed (with all characters
  92.              between X'00' and X'1F', and X'FF' changed to a blank).  This
  93.              line is followed by a line containing the high-order hex digit
  94.              of the byte directly above it.  Then another line is printed
  95.              showing the low-order hex digit in a similar fashion.  NOHEX is
  96.              the default.
  97.  
  98. HEADER       specifies that before the first line from the file is printed,
  99.              and after every PAGESIZE - (LPI/2) lines after that, a formfeed
  100.              is to be sent to the printer to position it at the top of form.
  101.              A "page header" is then printed which gives the input filespec,
  102.              the date it was last updated, the date and time the PRT command
  103.              was issued, and the page number.  This header is followed by
  104.              LPI/2 - 1 blank lines (2 if LPI 6, 3 if LPI 8) prior to printing
  105.              the first/next line from the input file.  HEADER is the default
  106.              unless CC (see below) is in effect.
  107.  
  108. UHEADER      works in a similar fashion to HEADER, except you are prompted
  109.              to enter a heading from the terminal to be used in place of the
  110.              one generated by the PRT command.  If the first character of
  111.              the header is ",", then it can be followed by up to 50 characters
  112.              that are used to replace "date last updated" and "current date and
  113.              time" fields mentioned above.  If the entered header does not
  114.              begin with a comma, it can contain up to 70 characters which
  115.              replace all fields in the page heading except the page number.
  116.  
  117. NOHEADER     causes LPI/2 blank lines to be printed at the top of each page
  118.              (i.e., a 1/2 inch blank margin is left at the top of the page).
  119.  
  120. CC           specifies that the carriage control characters imbeded within
  121.              the file (i.e., formfeeds and linefeeds) are to be used to
  122.              format the listing rather than the PRT command keeping track
  123.              of lines and performing page ejects and printing page headings.
  124.              If CC is in effect, any HEADER/UHEADER/NOHEADER specification
  125.              is ignored.  CC is the default if "filespec" contains a file
  126.              extension ("filetype") of "LST".  Any other extension causes
  127.              NOCC to be the default.
  128.  
  129. NOCC         causes PRT to keep track of the lines read from the input file
  130.              and to skip over page perforations as described for the "xHEADER"
  131.              options above.  Linefeeds encountered in the input file are
  132.              honored and used to increment the line count.  Formfeeds are
  133.              treated as linefeeds.  NOCC is the default unless "filespec"
  134.              contains a file extension ("filetype") of "LST".
  135.  
  136. LPI 6        specify the number of lines to be printed per vertical inch of
  137.     8        paper.  The only valid values are "6" and "8", with "6" being
  138.              the default.
  139.  
  140. PAGESIZE n   specifies the maximum number of lines that are to be printed on
  141.              a page prior to automatically sending a formfeed character to
  142.              the printer and printing the appropriate page heading.  The
  143.              actual number of lines from the input file that are printed on
  144.              a page is PAGESIZE - (LPI/2) less the number of linefeed and
  145.              formfeed characters encountered.  PAGESIZE 63 is the default
  146.              (unless CC is in effect, in which case PAGESIZE is ignored).
  147.              "n" must be 5 or larger.
  148.  
  149. FROM n       specifies the line number of the input file from which printing
  150.              is to commense.  This can be used to print the first n-1 lines
  151.              (ignoring linefeeds and formfeeds) in the file.  "FROM 1" is
  152.              the default.
  153.  
  154. FOR n        specifies the maximum number of lines (ignoring linefeeds and
  155.              formfeeds) that are to be read from the file.  This can be used,
  156.              often in conjunction with the FROM option, to only print a
  157.              selected number of lines from the file.  "FOR 32767" is the
  158.              default.
  159.  
  160. notes:
  161.  
  162. Options can be prefixed with a "/" character to be compatible with the
  163. options on some other PC-DOS commands, although the "/" specification is not
  164. required.  If and when a ";" is encounted in the option specification,
  165. it and any characters that follow are ignored.  While this technique can
  166. be used to place comments on the end of the command line, its primary use
  167. is to suppress the prompt for the entry of options when the default option
  168. values are satisfactory.
  169.  
  170. The PRT command is written in IBM PASCAL.  The source code is available
  171. and the "VALUE" section can be examined to modify the printer codes (see
  172. the "INIT_xxxx_ON" and "INIT_xxxx_OFF" variables) if they differ slightly
  173. for your printer.
  174.  
  175. The PRT command has been tested only with the Epson MX-100 printer.  It
  176. should also work with the MX-80 printer since they are very similar (and
  177. the PRT command doesn't use any of the MX-100's graphics features),
  178. although this has never been verified (due to the lack of an MX-80
  179. printer to play with!).
  180.  
  181.